package lms.dwr.demo.service;

import lms.dwr.demo.common.ServiceException;
import lms.dwr.demo.model.ModelStudent;
import lms.dwr.demo.web.component.pagination.PaginationSupport;

public interface ServiceStudent
extends ServiceBase
{
	
	/**
	 * 
	 * @param id
	 * @return
	 * @throws ServiceException
	 */
	ModelStudent getStudentById(String id) throws ServiceException;
	
	/**
	 * 
	 * @param studentNo
	 * @return
	 * @throws ServiceException
	 */
	ModelStudent getStudentByNo(String studentNo) throws ServiceException;
	
	
	/**
	 * 
	 * @param entity
	 * @param pageSize
	 * @param startIndex
	 * @param order
	 * @param isDesc
	 * @return
	 * @throws ServiceException
	 */
	PaginationSupport<ModelStudent> getStudentPagination (ModelStudent entity,
			int pageSize,int startIndex,String order,Boolean isDesc) throws ServiceException;
	
	/**
	 * 
	 * @param entity
	 * @throws ServiceException
	 */
	void saveOrUpdate(ModelStudent entity) throws ServiceException;
	
	/**
	 * 
	 * @param id
	 * @throws ServiceException
	 */
	void removeStudentById(String id) throws ServiceException;
	
	/**
	 * 
	 * @param entity
	 * @throws ServiceException
	 */
	void removeStudentByEntity(ModelStudent entity) throws ServiceException;
	
}
